package com.qq.first_project.mapper;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.qq.first_project.entity.Product;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.qq.first_project.entity.vo.ProductVo;
import org.springframework.stereotype.Repository;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author Qiu
 * @since 2022-04-06
 */
@Repository
public interface ProductMapper extends BaseMapper<Product> {
    // 根据id查询
    Product getProductById(Long id);

    // 查询所有
    IPage<ProductVo> queryProductList(Page<ProductVo> page, String name);
}
